package com.wn.access;

import com.alibaba.fastjson.JSON;
import com.wn.access.entity.BankReqDto;
import com.wn.common.result.BaseResult;

/**
 * @author yellow Docter
 * @date 2023 -08-03
 * @desc
 */
public class JsonTest {

    public static void main(String[] args) {
        String json = "{\"respData\":{\"respCode\":\"6955d621-f22c-4c5b-bc42-3f1b706825b0\",\"respMsg\":\"成功\",\"status\":1,\"requestNo\":\"BO_REQ_CODE8c4447af\"}}";

        BankReqDto bankReqDto = JSON.parseObject(json, BankReqDto.class);
        System.out.println("bankReqDto = " + bankReqDto);
        BaseResult baseResult = JSON.parseObject(bankReqDto.getRespData(), BaseResult.class);
        System.out.println("baseResult = " + baseResult);
    }

}
